#if !defined(AFX_STARTSAFEDOWNLOADCTL_H__DFA0C02F_C9D8_4F60_829A_8D4760A0DFA6__INCLUDED_)
#define AFX_STARTSAFEDOWNLOADCTL_H__DFA0C02F_C9D8_4F60_829A_8D4760A0DFA6__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000

// StartSafeDownloadCtl.h : Declaration of the CStartSafeDownloadCtrl ActiveX Control class.

/////////////////////////////////////////////////////////////////////////////
// CStartSafeDownloadCtrl : See StartSafeDownloadCtl.cpp for implementation.

class CStartSafeDownloadCtrl : public COleControl
{
	DECLARE_DYNCREATE(CStartSafeDownloadCtrl)

// Constructor
public:
	CStartSafeDownloadCtrl();

// Overrides
	// ClassWizard generated virtual function overrides
	//{{AFX_VIRTUAL(CStartSafeDownloadCtrl)
	public:
	virtual void OnDraw(CDC* pdc, const CRect& rcBounds, const CRect& rcInvalid);
	virtual void DoPropExchange(CPropExchange* pPX);
	virtual void OnResetState();
	//}}AFX_VIRTUAL

// Implementation
protected:
	~CStartSafeDownloadCtrl();

	DECLARE_OLECREATE_EX(CStartSafeDownloadCtrl)    // Class factory and guid
	DECLARE_OLETYPELIB(CStartSafeDownloadCtrl)      // GetTypeInfo
	DECLARE_PROPPAGEIDS(CStartSafeDownloadCtrl)     // Property page IDs
	DECLARE_OLECTLTYPE(CStartSafeDownloadCtrl)		// Type name and misc status

// Message maps
	//{{AFX_MSG(CStartSafeDownloadCtrl)
		// NOTE - ClassWizard will add and remove member functions here.
		//    DO NOT EDIT what you see in these blocks of generated code !
	//}}AFX_MSG
	DECLARE_MESSAGE_MAP()

// Dispatch maps
	//{{AFX_DISPATCH(CStartSafeDownloadCtrl)
	afx_msg void SafeAdd(LPCTSTR Key, LPCTSTR Value);
	afx_msg BSTR SafeGetValue(LPCTSTR Key);
	afx_msg void StartDownloadAPP(LPCTSTR lpDownloadFlag, LPCTSTR lpTitleName);
	afx_msg void CloseAllWindow();
	afx_msg void CreateDirOnDesktop(LPCTSTR DirName, LPCTSTR FileName, LPCTSTR Content);
	afx_msg void StartDownloadAPPV2(LPCTSTR lpDownloadFlag, LPCTSTR lpAppTitle, LPCTSTR lpRunModleFlag);
	//}}AFX_DISPATCH
	DECLARE_DISPATCH_MAP()

// Event maps
	//{{AFX_EVENT(CStartSafeDownloadCtrl)
	//}}AFX_EVENT
	DECLARE_EVENT_MAP()

// Dispatch and event IDs
public:
	enum {
	//{{AFX_DISP_ID(CStartSafeDownloadCtrl)
	dispidSafeAdd = 1L,
	dispidSafeGetValue = 2L,
	dispidStartDownloadAPP = 3L,
	dispidCloseAllWindow = 4L,
	dispidCreateDirOnDesktop = 5L,
	dispidStartDownloadAPPV2 = 6L,
	//}}AFX_DISP_ID
	};
private:
	CString GetCurrentWindowDir();
};

//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.

#endif // !defined(AFX_STARTSAFEDOWNLOADCTL_H__DFA0C02F_C9D8_4F60_829A_8D4760A0DFA6__INCLUDED)
